import http from '/@/utils/request'



/**
 * 新增容器信息
 */
export const addContainer = (data) => {
    return http.request({
        url: '/container/add',
        method: 'put',
        data
    })
}
/**
 * 查询容器信息列表
 */
export const listContainer = (query) => {
    return http.request({
        url: '/container/list',
        method:'get',
        params:query
    })
}
/**
 * 查询容器信息二维码
 */
export const getContainerQr = (id) => {
    return http.request({
        url: '/container/list.qr?id=' + id,
        method:'get'
    })
}

export const generateQr = (count) => {
    return http.request({
        url: '/container/generate.qr?count=' + count,
        method:'get'
    })
}


/**
 * 修改容器信息
 */
export const updateContainer = (data) => {
    return http.request({
        url: '/container/update',
        method: 'put',
        data
    })
}

/**
 * 删除容器信息
 */
export const delContainer = (data) => {
    return http.request({
        url: '/container/delete' ,
        method: 'put',
        data
    })
}
